/*   Shotscreens
 *   Copyright (C) 2011, Andrew Lisin (http://crystalnix.com)
 *
 *   This program is free software: you can redistribute it and/or modify
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation, either version 3 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#ifndef SETTINGS_H
#define SETTINGS_H

#include <QSettings>

QT_BEGIN_NAMESPACE
class QKeySequence;
class QString;
class QVariant;
QT_END_NAMESPACE

class Settings {
public:
    static Settings& instance();

    // methods for interaction with settings:
    void setKey(const QKeySequence& key);
    QKeySequence getKey();

    QString getLogin();
    void setLogin(const QString& login);

    QString getPassword();
    void setPassword(const QString& password);

    QString getUploader();
    void setUploader(const QString& uploader);

    QString getPluginName();
    void setPluginName(const QString& pluginName);

//    void setPluginFileName(const QString& pluginFileName);

//    QString getPluginFileName();

    void setValue(QString name, QVariant); // this should be use only by plugins

private:
    Settings();
    Settings(const Settings&);
    Settings& operator=(Settings&);

    ~Settings();

    //static Settings sw;
    QSettings* settings;
};

#endif // SETTINGSWRAPPER_H
